﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="HostelAdd.aspx.cs" Inherits="UI.ModMini.HostelAdd" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title>宿舍信息管理</title>
     <link rel="stylesheet" type="text/css" href="../Styles/BaseStyle.css" />
    <script type="text/javascript" src="../JS/jsFunction.js"></script>
    <script src="../JS/calendar.js" type="text/javascript"></script>
      <style type="text/css">
      
        .style1
        {
            width: 125px;
        }
    </style>
</head>
<body>
    <form id="form1" runat="server">
     <br />
    &nbsp;<br />
    &nbsp;<p style="text-align: center; font-size: large;">
        <strong>宿舍信息管理</strong></p>
    <br />
    <table style="width: 60%;" align="center">
        <tr>
            <td class="style1">
                宿舍编号 
            </td>
            <td>
                <asp:TextBox ID="txtHostelCode" runat="server" CssClass="InputCss" Width="100px" 
                    TabIndex="0"  ></asp:TextBox>
           
                <asp:RequiredFieldValidator ID="rf5"  ControlToValidate="txtHostelCode" 
                    runat="server" ErrorMessage="必填项" ForeColor="Red"></asp:RequiredFieldValidator>
            </td>
        </tr>
        <tr>
            <td class="style1">
                宿舍性别 
            </td>
            <td>                    
             <asp:DropDownList ID="ddlHostelsex" runat="server" CssClass="InputCss">
            <asp:ListItem>男</asp:ListItem>
            <asp:ListItem>女</asp:ListItem>
            <asp:ListItem>混合</asp:ListItem>
           
        </asp:DropDownList>
            </td>
        </tr>
        <tr>
            <td class="style1">
                地址 
            </td>
            <td>
                <asp:TextBox ID="txtAddr" runat="server" CssClass="InputCss" Width="180px" 
                    TabIndex="2"></asp:TextBox>
            </td>
        </tr>
        <tr>
            <td class="style1">
                额定人数</td>
            <td>
               <asp:TextBox ID="txtReadyNum" runat="server" CssClass="InputCss" Width="100px" 
                    tabindex="3"></asp:TextBox>
            </td>
        </tr>
        
        <tr>
            <td class="style1">
               已住人数
            </td>
            <td>
               <asp:TextBox ID="txtInNum" runat="server" CssClass="InputCss" Width="100px" 
                    tabindex="4">0</asp:TextBox>
            </td>
        </tr>
        <tr>
            <td class="style1">
                备注
             </td>
            <td>
                <asp:TextBox ID="txtMemo" runat="server" CssClass="InputCss" Width="220px" 
                    TabIndex="10"></asp:TextBox>
            </td>
        </tr>
        
    </table>
    <p style="text-align: center;">
    <asp:Button ID="btnAdd" runat="server" Text="增加" OnClick="btnAdd_Click" 
            TabIndex="11" />
     &nbsp;<asp:Button ID="btnIn" runat="server" Text="入住"
            TabIndex="14" Enabled="False" style="height: 21px" />
    &nbsp;<asp:Button ID="btnUpdate" runat="server" Text="更新" OnClick="btnUpdate_Click" 
            TabIndex="14" Enabled="False" style="height: 21px" />

             &nbsp;<asp:Button ID="btnNoUse" runat="server" Text="退租" OnClick="btnNoUse_Click" 
            TabIndex="14" Enabled="False" style="height: 21px" />
              &nbsp;<asp:Button ID="btnReset" runat="server" Text="清空" OnClick="btnReset_Click" 
            TabIndex="13" />
    &nbsp;<asp:Button ID="btnDelete" runat="server" Text="删除" OnClick="btnDelete_Click"  OnClientClick="return confirm('确定要删除吗?\n');"
            TabIndex="15" Enabled="False" />
    &nbsp;<asp:Button ID="btnClose" runat="server" onclick="btnClose_Click" Text="关闭" 
            TabIndex="13" CausesValidation="False" style="height: 21px" />
    </p>
    <asp:GridView ID="gvList" Width="60%"  runat="server" HorizontalAlign="Center" 
         CssClass="td" AutoGenerateColumns="False">
         <Columns>
    <asp:BoundField DataField="DeptName" HeaderText="部门" SortExpression="DeptName">
                <ItemStyle Width="70px" />
            </asp:BoundField>
            <asp:BoundField DataField="EmpCode" HeaderText="工号" SortExpression="EmpCode">
                <ItemStyle Width="70px" />
            </asp:BoundField>
            <asp:BoundField DataField="EmpName" HeaderText="姓名" SortExpression="EmpName">
                <ItemStyle Width="90px" />
            </asp:BoundField>
              <asp:BoundField DataField="InTime" HeaderText="入住日期" DataFormatString="{0:d}"
                SortExpression="InTime" ItemStyle-HorizontalAlign="Center">
                <ItemStyle Width="90px" />
            </asp:BoundField>



                 </Columns>
    </asp:GridView>

    </form>
</body>
</html>
